unit uSettings;

interface

uses
  Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
  Dialogs, StdCtrls, ActnList, DB;

type
  TfrmSettings = class(TForm)
    Label1: TLabel;
    edtFileName: TEdit;
    Button1: TButton;
    Button2: TButton;
    ActionList1: TActionList;
    actCheckConnect: TAction;

    procedure actCheckConnectUpdate(Sender: TObject);
    procedure actCheckConnectExecute(Sender: TObject);
    procedure FormCreate(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
    class procedure Showform;
  end;

var
  frmSettings: TfrmSettings;

implementation

Uses uDM;

{$R *.dfm}

procedure TfrmSettings.actCheckConnectExecute(Sender: TObject);
begin
  //
end;

procedure TfrmSettings.actCheckConnectUpdate(Sender: TObject);
begin
  actCheckConnect.Enabled := Trim(edtFileName.Text) <> '';
end;

procedure TfrmSettings.FormCreate(Sender: TObject);
begin
  edtFileName.Text := dmData.MainDB.DatabaseName;
end;

class procedure TfrmSettings.Showform;
begin
  with TfrmSettings.Create(nil) do
  try
    ShowModal;
  finally
    Free;
  end;
end;

end.

